Clean data: Look at Plateau Longitudinal Sample concentrations for each day. Select which value from different run (out of the series of duplicate and dilution runs)

Visualize Raw Data

Create good_id vector and only select those datapoints

good_id<-c(75:83, 84:92, 93:109, 161, 164:170, 174, 193:198, 200, 204, 212:214, 218:229, 242, 245, 249, 258:266,  268:276, 278:286, 288:295, 328, 369:377, 379:386, 437:440, 443, 444, 446:448, 458:460, 472:474, 505, 507, 508, 535:543, 545:552, 585, 636:643, 703:705, 715:717, 729:731)

#create dataset of only selected points
chem_clean_long <- chem_long%>%
  filter(id %in% good_id)

#double check that Max Detection Limit is vaild
chem_clean_long_flagged<-chem_clean_long%>%
  filter(MaxDL_flag== 'Yes')

count(chem_clean_long_flagged)
## # A tibble: 1 x 1
##       n
##   <int>
## 1     7

Visualize Selected Data